home *** CD-ROM | disk | FTP | other *** search
/ Developer Helper 1: Phil & Dave's Excellent CD / Excellent CD HFS.raw / Moof / Goodies / DTS Goodies / Bechtels stuff / play.r < prev   
Text File  |  1988-08-29  |  4KB  |  175 lines

  1. /* The BNDL describes how to get to our ICN# resources
  2.  * so that the Finder can display the icon, and tell
  3.  * which application to open when a file of the associated type has 
  4.  * been opened.
  5.  */
  6. resource 'BNDL' (128) {
  7.     'aucd',
  8.     0,
  9.     {    /* array TypeArray: 2 elements */
  10.         /* [1] */
  11.         'ICN#',
  12.         {    /* array IDArray: 2 elements */
  13.             /* [1] */
  14.             0, 128,
  15.             /* [2] */
  16.             1, 129
  17.         },
  18.         /* [2] */
  19.         'FREF',
  20.         {    /* array IDArray: 2 elements */
  21.             /* [1] */
  22.             0, 128,
  23.             /* [2] */
  24.             1, 129
  25.         }
  26.     }
  27. };
  28.  
  29. resource 'FREF' (128) {
  30.     'APPL',
  31.     0,
  32.     ""
  33. };
  34.  
  35. resource 'FREF' (129) {
  36.     'trak',
  37.     1,
  38.     ""
  39. };
  40.  
  41. /* Our program icon.  This is what I look like,
  42.  * roughly.  Thanks to the Bill Atkinson’s Hypercard
  43.  * icon stack for my inspiration. (Ever notice how everybody
  44.  * looks pretty similar at 32 bits by 32 bits?)
  45.  */
  46. resource 'ICN#' (128) {
  47.     {    /* array: 2 elements */
  48.         /* [1] */
  49.         $"000F F000 003F FC00 006F 7E00 01FD F700"
  50.         $"03D3 C380 03B4 03C0 0780 03C0 0700 00E0"
  51.         $"0680 00E0 0680 00E0 0700 00E0 06FC 3FE0"
  52.         $"0FBF F6E0 0B2A 4A90 0B02 40D0 0584 21A0"
  53.         $"0578 1EA0 0500 01A0 0283 41C0 03C3 A340"
  54.         $"01E0 0A80 00AF DD80 00AD F700 00FC 0900"
  55.         $"006B F700 0079 DD00 005F 7900 004E D980"
  56.         $"0081 F0C0 0300 0030 1C00 001C E000 0007",
  57.         /* [2] */
  58.         $"000F F000 003F FC00 007F FE00 01FF FF00"
  59.         $"03FF FF80 03FF FFC0 07FF FFC0 07FF FFE0"
  60.         $"07FF FFE0 07FF FFE0 07FF FFE0 07FF FFE0"
  61.         $"0FFF FFE0 0FFF FFF0 0FFF FFF0 07FF FFE0"
  62.         $"07FF FFE0 07FF FFE0 03FF FFC0 03FF FFC0"
  63.         $"01FF FF80 00FF FF80 00FF FF00 00FF FF00"
  64.         $"007F FF00 007F FD00 005F F900 004F F980"
  65.         $"0081 F0C0 0300 0030 1C00 001C E000 0007"
  66.     }
  67. };
  68.  
  69. /* The ICN# for the documents "created" by this
  70.  * application.  Actually, the Audio CD Access
  71.  * file returns this icon to the finder.  I must
  72.  * supply this icon as well, so that if somebody
  73.  * copies a audio CD track to a hard disk, it will
  74.  * still show up with the proper icon.  (Now there's
  75.  * a useless operation... copy an audio track to
  76.  * a hard disk...)
  77.  */
  78. resource 'ICN#' (129) {
  79.     {    /* array: 2 elements */
  80.         /* [1] */
  81.         $"FFFF E000 8000 3000 8200 2800 8200 2400"
  82.         $"8300 2200 8280 2100 8240 3F80 8240 0080"
  83.         $"8240 0080 8247 FFFC 8288 3F82 9E10 D561"
  84.         $"BE11 AAB1 BE13 5559 9C16 AAAD 8015 5F55"
  85.         $"801A B1AB 801D 6ED7 801A DF6B 801D 5957"
  86.         $"801A D96B 801D 6ED7 801A B1AB 8015 5F57"
  87.         $"8016 AAAF 8013 555D 8011 AABD 8010 D579"
  88.         $"8010 3FF1 801F FFFF 8010 0001 FFEF FFFE",
  89.         /* [2] */
  90.         $"FFFF E000 FFFF F000 FFFF F800 FFFF FC00"
  91.         $"FFFF FE00 FFFF FF00 FFFF FF80 FFFF FF80"
  92.         $"FFFF FF80 FFFF FFFC FFFF FFFE FFFF FFFF"
  93.         $"FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF"
  94.         $"FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF"
  95.         $"FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF"
  96.         $"FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF"
  97.         $"FFFF FFFF FFFF FFFF FFFF FFFF FFEF FFFE"
  98.     }
  99. };
  100.  
  101. /* My version comment. */
  102. type 'aucd' as 'STR ';
  103.  
  104. data 'aucd' (0) {
  105.     "Play demo 1.1"
  106. };
  107.  
  108. /* This DITL, ALRT, ICON triplet makes up my error routine
  109.  * dialog box.  The ALRT defines the layout of the DITL and
  110.  * ICON.  The DITL contains a button marked "OK", plus three
  111.  * spaces for ParamText() to fill in (I don't display the fourth
  112.  * possible parameter to ParamText()).
  113.  */
  114. resource 'DITL' (128, "Error", purgeable) {
  115.     {    /* array DITLarray: 5 elements */
  116.         /* [1] */
  117.         {122, 226, 142, 286},
  118.         Button {
  119.             enabled,
  120.             "OK"
  121.         },
  122.         /* [2] */
  123.         {17, 67, 39, 286},
  124.         StaticText {
  125.             disabled,
  126.             "^0"
  127.         },
  128.         /* [3] */
  129.         {49, 67, 68, 108},
  130.         StaticText {
  131.             disabled,
  132.             "^1"
  133.         },
  134.         /* [4] */
  135.         {24, 18, 56, 50},
  136.         Icon {
  137.             disabled,
  138.             128
  139.         },
  140.         /* [5] */
  141.         {49, 117, 114, 286},
  142.         StaticText {
  143.             enabled,
  144.             "^2"
  145.         }
  146.     }
  147. };
  148.  
  149. resource 'ALRT' (128, "Error") {
  150.     {50, 72, 202, 410},
  151.     128,
  152.     {    /* array: 4 elements */
  153.         /* [1] */
  154.         OK, visible, silent,
  155.         /* [2] */
  156.         OK, visible, silent,
  157.         /* [3] */
  158.         OK, visible, silent,
  159.         /* [4] */
  160.         OK, visible, silent
  161.     }
  162. };
  163.  
  164. resource 'ICON' (128) {
  165.     $"FFFF E000 8000 3000 8200 2800 8200 2400"
  166.     $"8300 2200 8280 2100 8240 3F80 8240 0080"
  167.     $"8240 0080 8247 FFFC 8288 3F82 9E10 D561"
  168.     $"BE11 AAB1 BE13 5559 9C16 AAAD 8015 5F55"
  169.     $"801A B1AB 801D 6ED7 801A DF6B 801D 5957"
  170.     $"801A D96B 801D 6ED7 801A B1AB 8015 5F57"
  171.     $"8016 AAAF 8013 555D 8011 AABD 8010 D579"
  172.     $"8010 3FF1 801F FFFF 8010 0001 FFEF FFFE"
  173. };
  174.  
  175.